#!/usr/bin/perl
use strict;
use lib "lib/";

use Data::Dumper;
use CSS::Builder::Document;
use CSS::Builder::Property;

use CSS::Builder::Name;
use CSS::Builder::Name::Simple;

use CSS::Builder::Property::Margin;

my $document = CSS::Builder::Document->new();


     my $property = CSS::Builder::Property->new();
     #$propery->mode('compact');
     $property->compact('1');
     $property->name_join_sym(' , ');

     my $name = CSS::Builder::Name->new();
     #$name->reject_dupl(1);

     my $simple = CSS::Builder::Name::Simple->new();
     #$simple->type('class');
     #$simple->value('mt20');
     $name->list_push($simple);

     my $simple2 = CSS::Builder::Name::Simple->new();
     #$simple2->type('class');
     #$simple2->value('mt20');
     $name->list_push($simple2);


     $property->name($name);

     my $margin = CSS::Builder::Property::Margin->new(
         compact => 0,
     );
     $margin->element('px');
     $margin->top(20);
     $margin->right(10);
     #$property->attr('cool');

     $property->list_push($margin);




     $document->list_push($property);




print $document->css;
print Dumper $document;